#{extends 'main.html' /}

<br>
<ul>
	<br>
</ul>
#{if controllers.Application.isAdminhelper()}
<form action="@{Application.usersList()}" method="GET">

	<input type="submit" value="View Users list" />

</form>

<!-- @start @author mohammed mattr

this button retrieves calls the logview html to retieve users actions -->
#{/if} #{if controllers.Application.isAdminhelper()}

<form action="@{Application.LogView()}" method="GET" id=x>

	<input type="submit" value="View Logs"
		style="border-top-style: ridge; background-color: orange;" />

</form>
#{/if}

<!-- @End mohammed mattr-->

<!-- Start of author @Yasmine A.
there are two lists here,TopicTitle is a list that gets all topic
 titles available on the website. 
Another list TutorialTitle gets all published tutorial titles available
 on the website -->
<table border="0">
	<tr>
		<td colspan="2" style="background-color: #FFA500;">
			<h1>General Updates</h1> <a
			href="@{Application.followedUpdatesByTopic()}">Filter by followed
				Topics only </a><br> <a
			href="@{Application.followedUpdatesByTutorial()}">Filter by
				followed Tutorials only </a><br> <a
			href="@{Application.followedUpdatesByUser()}">Filter by followed
				Users only </a><br>
		</td>
	</tr>
	<ul>

	</ul>

	<tr valign="top">
		<td style="background-color: #778899; width: 200px; text-align: top;">

			<a><u><b>Choose a Topic</b> </u> </a> #{ifnot topics}
			<p>There are no topics yet..</p> #{/ifnot} #{list items:topics,
			as:'TopicTitle'}

			<ul>

				<li><a href="/Topics/topicView?topicId=${TopicTitle.id}"
					value="${TopicTitle.topicName}">${TopicTitle.topicName} 
				</li>
			</ul> #{/list}</td>



		<td
			style="background-color: #eeeeee; height: 200px; width: 1000px; text-align: top;">
			<p> <b>Tutorials</b></p>
			#{ifnot tutorials}
			<p>No tutorials created yet..</p> #{/ifnot} #{list items:tutorials,
			as:'TutorialTitle'}

			<ul>
				<li><a href="/Tutorials/tutorialPage?tutId=${TutorialTitle.id}">${TutorialTitle.title}</a>
				</li>
			</ul>

			<form action="@{Application.updates()}" method="GET">
				<div id="${TutorialTitle.id}"></div>
			</form> #{/list}</td>
	</tr>


</table>
<!--End of author @Yasmine A. -->